package com.example.daydayup.designPatterns.study6;


/**
 * Description: <br/>
 *
 * @author: wells <br/>
 * @since 2024-04-1 16:46
 */
public class CoffeeBar {
    public static void main(String[] args) {
        com.example.daydayup.designPatterns.study6.Drink order = new com.example.daydayup.designPatterns.study6.Decaf();
        System.out.println("order1 price:" + order.cost());
        System.out.println("order1 desc:" + order.getDescription());
        System.out.println("****************");
        order = new com.example.daydayup.designPatterns.study6.Decaf();
        order = new com.example.daydayup.designPatterns.study6.LongBlack(order);
        order = new com.example.daydayup.designPatterns.study6.Milk(order);
        order = new com.example.daydayup.designPatterns.study6.Chocolate(order);
        order = new com.example.daydayup.designPatterns.study6.Chocolate(order);
        System.out.println("order2 price:" + order.cost());
        System.out.println("order2 desc:" + order.getDescription());
    }
}
